package tank.task.lagou.framework;

import org.apache.catalina.startup.WebappServiceLoader;
import org.springframework.web.WebApplicationInitializer;

import javax.servlet.ServletContainerInitializer;
import javax.servlet.ServletContext;
import javax.servlet.ServletException;
import javax.servlet.annotation.HandlesTypes;
import java.util.Set;
import java.util.logging.Logger;


@HandlesTypes(MyWebApplicationInitializer.class)
public class MySpringServletContainerInitializer implements ServletContainerInitializer {
    Logger logger = Logger.getLogger("MySpringServletContainerInitializer");
    public void onStartup(Set<Class<?>> set, ServletContext servletContext) throws ServletException {
        WebappServiceLoader w;
        logger.info("MySpringServletContainerInitializer onStartup");
        System.out.println("MySpringServletContainerInitializer onStartup");
        new MyWebApplicationInitializer().onStartup(servletContext);
    }
}
